<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
 <head>
  <meta http-equiv="content-type" content="text/html; charset=UTF-8">
  <title>MongoDB 驱动类</title>
<link media="all" rel="stylesheet" type="text/css" href="styles/03e73060321a0a848018724a6c83de7f-theme-base.css" />
<link media="all" rel="stylesheet" type="text/css" href="styles/03e73060321a0a848018724a6c83de7f-theme-medium.css" />

 </head>
 <body class="docs"><div class="navbar navbar-fixed-top">
  <div class="navbar-inner clearfix">
    <ul class="nav" style="width: 100%">
      <li style="float: left;"><a href="mongodb.security.script_injection.html">« Script Injection Attacks</a></li>
      <li style="float: right;"><a href="class.mongodb-driver-manager.html">MongoDB\Driver\Manager »</a></li>
    </ul>
  </div>
</div>
<div id="breadcrumbs" class="clearfix">
  <ul class="breadcrumbs-container">
    <li><a href="index.html">PHP Manual</a></li>
    <li><a href="set.mongodb.html">MongoDB</a></li>
    <li>MongoDB 驱动类</li>
  </ul>
</div>
<div id="layout">
  <div id="layout-content"><div id="book.mongodb" class="book">
  <h1 class="title">MongoDB 驱动类</h1>
  

  
 





  
 





  
 





  
 






  
 





  
 





  
 






  
 





  
 






  
 






  
 





  
 





  
 





 <ul class="chunklist chunklist_book"><li><a href="class.mongodb-driver-manager.html">MongoDB\Driver\Manager</a> — The MongoDB\Driver\Manager class<ul class="chunklist chunklist_book chunklist_children"><li><a href="mongodb-driver-manager.addsubscriber.html">MongoDB\Driver\Manager::addSubscriber</a> — Registers a monitoring event subscriber with this Manager</li><li><a href="mongodb-driver-manager.construct.html">MongoDB\Driver\Manager::__construct</a> — Create new MongoDB Manager</li><li><a href="mongodb-driver-manager.createclientencryption.html">MongoDB\Driver\Manager::createClientEncryption</a> — Create a new ClientEncryption object</li><li><a href="mongodb-driver-manager.executebulkwrite.html">MongoDB\Driver\Manager::executeBulkWrite</a> — Execute one or more write operations</li><li><a href="mongodb-driver-manager.executecommand.html">MongoDB\Driver\Manager::executeCommand</a> — Execute a database command</li><li><a href="mongodb-driver-manager.executequery.html">MongoDB\Driver\Manager::executeQuery</a> — Execute a database query</li><li><a href="mongodb-driver-manager.executereadcommand.html">MongoDB\Driver\Manager::executeReadCommand</a> — Execute a database command that reads</li><li><a href="mongodb-driver-manager.executereadwritecommand.html">MongoDB\Driver\Manager::executeReadWriteCommand</a> — Execute a database command that reads and writes</li><li><a href="mongodb-driver-manager.executewritecommand.html">MongoDB\Driver\Manager::executeWriteCommand</a> — Execute a database command that writes</li><li><a href="mongodb-driver-manager.getencryptedfieldsmap.html">MongoDB\Driver\Manager::getEncryptedFieldsMap</a> — Return the encryptedFieldsMap auto encryption option for the Manager</li><li><a href="mongodb-driver-manager.getreadconcern.html">MongoDB\Driver\Manager::getReadConcern</a> — Return the ReadConcern for the Manager</li><li><a href="mongodb-driver-manager.getreadpreference.html">MongoDB\Driver\Manager::getReadPreference</a> — Return the ReadPreference for the Manager</li><li><a href="mongodb-driver-manager.getservers.html">MongoDB\Driver\Manager::getServers</a> — Return the servers to which this manager is connected</li><li><a href="mongodb-driver-manager.getwriteconcern.html">MongoDB\Driver\Manager::getWriteConcern</a> — Return the WriteConcern for the Manager</li><li><a href="mongodb-driver-manager.removesubscriber.html">MongoDB\Driver\Manager::removeSubscriber</a> — Unregisters a monitoring event subscriber with this Manager</li><li><a href="mongodb-driver-manager.selectserver.html">MongoDB\Driver\Manager::selectServer</a> — Select a server matching a read preference</li><li><a href="mongodb-driver-manager.startsession.html">MongoDB\Driver\Manager::startSession</a> — Start a new client session for use with this client</li></ul></li><li><a href="class.mongodb-driver-command.html">MongoDB\Driver\Command</a> — The MongoDB\Driver\Command class<ul class="chunklist chunklist_book chunklist_children"><li><a href="mongodb-driver-command.construct.html">MongoDB\Driver\Command::__construct</a> — Create a new Command</li></ul></li><li><a href="class.mongodb-driver-query.html">MongoDB\Driver\Query</a> — The MongoDB\Driver\Query class<ul class="chunklist chunklist_book chunklist_children"><li><a href="mongodb-driver-query.construct.html">MongoDB\Driver\Query::__construct</a> — Create a new Query</li></ul></li><li><a href="class.mongodb-driver-bulkwrite.html">MongoDB\Driver\BulkWrite</a> — The MongoDB\Driver\BulkWrite class<ul class="chunklist chunklist_book chunklist_children"><li><a href="mongodb-driver-bulkwrite.construct.html">MongoDB\Driver\BulkWrite::__construct</a> — Create a new BulkWrite</li><li><a href="mongodb-driver-bulkwrite.count.html">MongoDB\Driver\BulkWrite::count</a> — Count number of write operations in the bulk</li><li><a href="mongodb-driver-bulkwrite.delete.html">MongoDB\Driver\BulkWrite::delete</a> — Add a delete operation to the bulk</li><li><a href="mongodb-driver-bulkwrite.insert.html">MongoDB\Driver\BulkWrite::insert</a> — Add an insert operation to the bulk</li><li><a href="mongodb-driver-bulkwrite.update.html">MongoDB\Driver\BulkWrite::update</a> — Add an update operation to the bulk</li></ul></li><li><a href="class.mongodb-driver-writeconcern.html">MongoDB\Driver\WriteConcern</a> — The MongoDB\Driver\WriteConcern class<ul class="chunklist chunklist_book chunklist_children"><li><a href="mongodb-driver-writeconcern.bsonserialize.html">MongoDB\Driver\WriteConcern::bsonSerialize</a> — Returns an object for BSON serialization</li><li><a href="mongodb-driver-writeconcern.construct.html">MongoDB\Driver\WriteConcern::__construct</a> — Create a new WriteConcern</li><li><a href="mongodb-driver-writeconcern.getjournal.html">MongoDB\Driver\WriteConcern::getJournal</a> — Returns the WriteConcern's &quot;journal&quot; option</li><li><a href="mongodb-driver-writeconcern.getw.html">MongoDB\Driver\WriteConcern::getW</a> — Returns the WriteConcern's &quot;w&quot; option</li><li><a href="mongodb-driver-writeconcern.getwtimeout.html">MongoDB\Driver\WriteConcern::getWtimeout</a> — Returns the WriteConcern's &quot;wtimeout&quot; option</li><li><a href="mongodb-driver-writeconcern.isdefault.html">MongoDB\Driver\WriteConcern::isDefault</a> — Checks if this is the default write concern</li><li><a href="mongodb-driver-writeconcern.serialize.html">MongoDB\Driver\WriteConcern::serialize</a> — Serialize a WriteConcern</li><li><a href="mongodb-driver-writeconcern.unserialize.html">MongoDB\Driver\WriteConcern::unserialize</a> — Unserialize a WriteConcern</li></ul></li><li><a href="class.mongodb-driver-readpreference.html">MongoDB\Driver\ReadPreference</a> — The MongoDB\Driver\ReadPreference class<ul class="chunklist chunklist_book chunklist_children"><li><a href="mongodb-driver-readpreference.bsonserialize.html">MongoDB\Driver\ReadPreference::bsonSerialize</a> — Returns an object for BSON serialization</li><li><a href="mongodb-driver-readpreference.construct.html">MongoDB\Driver\ReadPreference::__construct</a> — Create a new ReadPreference</li><li><a href="mongodb-driver-readpreference.gethedge.html">MongoDB\Driver\ReadPreference::getHedge</a> — Returns the ReadPreference's &quot;hedge&quot; option</li><li><a href="mongodb-driver-readpreference.getmaxstalenessseconds.html">MongoDB\Driver\ReadPreference::getMaxStalenessSeconds</a> — Returns the ReadPreference's &quot;maxStalenessSeconds&quot; option</li><li><a href="mongodb-driver-readpreference.getmode.html">MongoDB\Driver\ReadPreference::getMode</a> — Returns the ReadPreference's &quot;mode&quot; option</li><li><a href="mongodb-driver-readpreference.getmodestring.html">MongoDB\Driver\ReadPreference::getModeString</a> — Returns the ReadPreference's &quot;mode&quot; option as a string</li><li><a href="mongodb-driver-readpreference.gettagsets.html">MongoDB\Driver\ReadPreference::getTagSets</a> — Returns the ReadPreference's &quot;tagSets&quot; option</li><li><a href="mongodb-driver-readpreference.serialize.html">MongoDB\Driver\ReadPreference::serialize</a> — Serialize a ReadPreference</li><li><a href="mongodb-driver-readpreference.unserialize.html">MongoDB\Driver\ReadPreference::unserialize</a> — Unserialize a ReadPreference</li></ul></li><li><a href="class.mongodb-driver-readconcern.html">MongoDB\Driver\ReadConcern</a> — The MongoDB\Driver\ReadConcern class<ul class="chunklist chunklist_book chunklist_children"><li><a href="mongodb-driver-readconcern.bsonserialize.html">MongoDB\Driver\ReadConcern::bsonSerialize</a> — Returns an object for BSON serialization</li><li><a href="mongodb-driver-readconcern.construct.html">MongoDB\Driver\ReadConcern::__construct</a> — Create a new ReadConcern</li><li><a href="mongodb-driver-readconcern.getlevel.html">MongoDB\Driver\ReadConcern::getLevel</a> — Returns the ReadConcern's &quot;level&quot; option</li><li><a href="mongodb-driver-readconcern.isdefault.html">MongoDB\Driver\ReadConcern::isDefault</a> — Checks if this is the default read concern</li><li><a href="mongodb-driver-readconcern.serialize.html">MongoDB\Driver\ReadConcern::serialize</a> — Serialize a ReadConcern</li><li><a href="mongodb-driver-readconcern.unserialize.html">MongoDB\Driver\ReadConcern::unserialize</a> — Unserialize a ReadConcern</li></ul></li><li><a href="class.mongodb-driver-cursor.html">MongoDB\Driver\Cursor</a> — The MongoDB\Driver\Cursor class<ul class="chunklist chunklist_book chunklist_children"><li><a href="mongodb-driver-cursor.construct.html">MongoDB\Driver\Cursor::__construct</a> — Create a new Cursor (not used)</li><li><a href="mongodb-driver-cursor.current.html">MongoDB\Driver\Cursor::current</a> — Returns the current element</li><li><a href="mongodb-driver-cursor.getid.html">MongoDB\Driver\Cursor::getId</a> — Returns the ID for this cursor</li><li><a href="mongodb-driver-cursor.getserver.html">MongoDB\Driver\Cursor::getServer</a> — Returns the server associated with this cursor</li><li><a href="mongodb-driver-cursor.isdead.html">MongoDB\Driver\Cursor::isDead</a> — Checks if the cursor is exhausted or may have additional results</li><li><a href="mongodb-driver-cursor.key.html">MongoDB\Driver\Cursor::key</a> — Returns the current result's index within the cursor</li><li><a href="mongodb-driver-cursor.next.html">MongoDB\Driver\Cursor::next</a> — Advances the cursor to the next result</li><li><a href="mongodb-driver-cursor.rewind.html">MongoDB\Driver\Cursor::rewind</a> — Rewind the cursor to the first result</li><li><a href="mongodb-driver-cursor.settypemap.html">MongoDB\Driver\Cursor::setTypeMap</a> — Sets a type map to use for BSON unserialization</li><li><a href="mongodb-driver-cursor.toarray.html">MongoDB\Driver\Cursor::toArray</a> — Returns an array containing all results for this cursor</li><li><a href="mongodb-driver-cursor.valid.html">MongoDB\Driver\Cursor::valid</a> — Checks if the current position in the cursor is valid</li></ul></li><li><a href="class.mongodb-driver-cursorid.html">MongoDB\Driver\CursorId</a> — The MongoDB\Driver\CursorId class<ul class="chunklist chunklist_book chunklist_children"><li><a href="mongodb-driver-cursorid.construct.html">MongoDB\Driver\CursorId::__construct</a> — Create a new CursorId (not used)</li><li><a href="mongodb-driver-cursorid.serialize.html">MongoDB\Driver\CursorId::serialize</a> — Serialize a CursorId</li><li><a href="mongodb-driver-cursorid.tostring.html">MongoDB\Driver\CursorId::__toString</a> — String representation of the cursor ID</li><li><a href="mongodb-driver-cursorid.unserialize.html">MongoDB\Driver\CursorId::unserialize</a> — Unserialize a CursorId</li></ul></li><li><a href="class.mongodb-driver-server.html">MongoDB\Driver\Server</a> — The MongoDB\Driver\Server class<ul class="chunklist chunklist_book chunklist_children"><li><a href="mongodb-driver-server.construct.html">MongoDB\Driver\Server::__construct</a> — Create a new Server (not used)</li><li><a href="mongodb-driver-server.executebulkwrite.html">MongoDB\Driver\Server::executeBulkWrite</a> — Execute one or more write operations on this server</li><li><a href="mongodb-driver-server.executecommand.html">MongoDB\Driver\Server::executeCommand</a> — Execute a database command on this server</li><li><a href="mongodb-driver-server.executequery.html">MongoDB\Driver\Server::executeQuery</a> — Execute a database query on this server</li><li><a href="mongodb-driver-server.executereadcommand.html">MongoDB\Driver\Server::executeReadCommand</a> — Execute a database command that reads on this server</li><li><a href="mongodb-driver-server.executereadwritecommand.html">MongoDB\Driver\Server::executeReadWriteCommand</a> — Execute a database command that reads and writes on this server</li><li><a href="mongodb-driver-server.executewritecommand.html">MongoDB\Driver\Server::executeWriteCommand</a> — Execute a database command that writes on this server</li><li><a href="mongodb-driver-server.gethost.html">MongoDB\Driver\Server::getHost</a> — Returns the hostname of this server</li><li><a href="mongodb-driver-server.getinfo.html">MongoDB\Driver\Server::getInfo</a> — Returns an array of information describing this server</li><li><a href="mongodb-driver-server.getlatency.html">MongoDB\Driver\Server::getLatency</a> — Returns the latency of this server in milliseconds</li><li><a href="mongodb-driver-server.getport.html">MongoDB\Driver\Server::getPort</a> — Returns the port on which this server is listening</li><li><a href="mongodb-driver-server.getserverdescription.html">MongoDB\Driver\Server::getServerDescription</a> — Returns a ServerDescription for this server</li><li><a href="mongodb-driver-server.gettags.html">MongoDB\Driver\Server::getTags</a> — Returns an array of tags describing this server in a replica set</li><li><a href="mongodb-driver-server.gettype.html">MongoDB\Driver\Server::getType</a> — Returns an integer denoting the type of this server</li><li><a href="mongodb-driver-server.isarbiter.html">MongoDB\Driver\Server::isArbiter</a> — Checks if this server is an arbiter member of a replica set</li><li><a href="mongodb-driver-server.ishidden.html">MongoDB\Driver\Server::isHidden</a> — Checks if this server is a hidden member of a replica set</li><li><a href="mongodb-driver-server.ispassive.html">MongoDB\Driver\Server::isPassive</a> — Checks if this server is a passive member of a replica set</li><li><a href="mongodb-driver-server.isprimary.html">MongoDB\Driver\Server::isPrimary</a> — Checks if this server is a primary member of a replica set</li><li><a href="mongodb-driver-server.issecondary.html">MongoDB\Driver\Server::isSecondary</a> — Checks if this server is a secondary member of a replica set</li></ul></li><li><a href="class.mongodb-driver-writeconcernerror.html">MongoDB\Driver\WriteConcernError</a> — The MongoDB\Driver\WriteConcernError class<ul class="chunklist chunklist_book chunklist_children"><li><a href="mongodb-driver-writeconcernerror.getcode.html">MongoDB\Driver\WriteConcernError::getCode</a> — Returns the WriteConcernError's error code</li><li><a href="mongodb-driver-writeconcernerror.getinfo.html">MongoDB\Driver\WriteConcernError::getInfo</a> — Returns metadata document for the WriteConcernError</li><li><a href="mongodb-driver-writeconcernerror.getmessage.html">MongoDB\Driver\WriteConcernError::getMessage</a> — Returns the WriteConcernError's error message</li></ul></li><li><a href="class.mongodb-driver-writeerror.html">MongoDB\Driver\WriteError</a> — The MongoDB\Driver\WriteError class<ul class="chunklist chunklist_book chunklist_children"><li><a href="mongodb-driver-writeerror.getcode.html">MongoDB\Driver\WriteError::getCode</a> — Returns the WriteError's error code</li><li><a href="mongodb-driver-writeerror.getindex.html">MongoDB\Driver\WriteError::getIndex</a> — Returns the index of the write operation corresponding to this WriteError</li><li><a href="mongodb-driver-writeerror.getinfo.html">MongoDB\Driver\WriteError::getInfo</a> — Returns metadata document for the WriteError</li><li><a href="mongodb-driver-writeerror.getmessage.html">MongoDB\Driver\WriteError::getMessage</a> — Returns the WriteError's error message</li></ul></li><li><a href="class.mongodb-driver-writeresult.html">MongoDB\Driver\WriteResult</a> — The MongoDB\Driver\WriteResult class<ul class="chunklist chunklist_book chunklist_children"><li><a href="mongodb-driver-writeresult.getdeletedcount.html">MongoDB\Driver\WriteResult::getDeletedCount</a> — Returns the number of documents deleted</li><li><a href="mongodb-driver-writeresult.getinsertedcount.html">MongoDB\Driver\WriteResult::getInsertedCount</a> — Returns the number of documents inserted (excluding upserts)</li><li><a href="mongodb-driver-writeresult.getmatchedcount.html">MongoDB\Driver\WriteResult::getMatchedCount</a> — Returns the number of documents selected for update</li><li><a href="mongodb-driver-writeresult.getmodifiedcount.html">MongoDB\Driver\WriteResult::getModifiedCount</a> — Returns the number of existing documents updated</li><li><a href="mongodb-driver-writeresult.getserver.html">MongoDB\Driver\WriteResult::getServer</a> — Returns the server associated with this write result</li><li><a href="mongodb-driver-writeresult.getupsertedcount.html">MongoDB\Driver\WriteResult::getUpsertedCount</a> — Returns the number of documents inserted by an upsert</li><li><a href="mongodb-driver-writeresult.getupsertedids.html">MongoDB\Driver\WriteResult::getUpsertedIds</a> — Returns an array of identifiers for upserted documents</li><li><a href="mongodb-driver-writeresult.getwriteconcernerror.html">MongoDB\Driver\WriteResult::getWriteConcernError</a> — Returns any write concern error that occurred</li><li><a href="mongodb-driver-writeresult.getwriteerrors.html">MongoDB\Driver\WriteResult::getWriteErrors</a> — Returns any write errors that occurred</li><li><a href="mongodb-driver-writeresult.isacknowledged.html">MongoDB\Driver\WriteResult::isAcknowledged</a> — Returns whether the write was acknowledged</li></ul></li></ul></div></div></div></body></html>